﻿ 

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e7f4 100%);
    color: var(--dark-color);
    line-height: 1.6;
 
}
 

/* 主内容区样式 */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    transition: all 0.3s ease;
}

.header {
    height: var(--header-height);
    background-color: white;
    display: flex;
    align-items: center;
    padding: 0 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 10;
}
  
 

.header-actions {
    display: flex;
    align-items: center;
    margin-left: 20px;
}
 
/* 内容区域 */
.content-area {
    flex: 1;
    display: flex;
    height:98vh;
}

.notes-list {
    width: 320px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    /*overflow: hidden;*/
    display: flex;
    flex-direction: column;
    margin-right: 20px;
    transition: all 0.3s;
}

.list-header {
    padding: 10px 20px;
    border-bottom: 1px solid #eee;
}

.notes-container {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.note-item {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
    position: relative;
}

    .note-item:hover {
        background: #f8f9ff;
    }

    .note-item.active {
        background: rgba(67, 97, 238, 0.08);
        border-left: 3px solid var(--primary-color);
    }

.note-title {
    font-weight: 600;
    margin-bottom: 5px;
    display: flex;
    justify-content: space-between;
}

.note-date {
    font-size: 0.8rem;
    color: var(--gray-color);
}
 
.note-tags {
    display: flex;
    margin-top: 10px;
    flex-wrap: wrap;
    gap: 5px;
}

.el-tag {
    border-radius: 20px;
    border: none;
}

/* 笔记编辑器 */
.note-editor {
    flex: 1;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

.editor-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
    flex-wrap: wrap;
}

.editor-header-content {
    flex: 1;
    min-width: 250px;
}

 
 

.editor-content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

 


.pre {
    padding: 10px;
    overflow-x: auto;
    white-space: pre-wrap;
    word-wrap: break-word;
}
 

/* 响应式设计 */
@media (max-width: 1200px) {
    .content-area {
        flex-direction: column;
    }

    .notes-list {
        width: 100%;
        margin-right: 0;
        margin-bottom: 20px;
        max-height: 300px;
    }

    .note-editor {
        min-height: 500px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        position: absolute;
        transform: translateX(-100%);
        z-index: 1000;
    }

        .sidebar.active {
            transform: translateX(0);
            width: 280px;
        }

        .sidebar.collapsed {
            width: 80px;
            transform: translateX(-100%);
        }

            .sidebar.collapsed.active {
                transform: translateX(0);
            }

    .menu-toggle {
        display: block !important;
    }

    .header {
        padding: 0 15px;
    }

    .search-bar {
        max-width: 100%;
    }

    .editor-header {
        padding: 15px;
        flex-direction: column;
    }

    .editor-actions {
        width: 100%;
        justify-content: flex-start;
        margin-top: 15px;
    }

    .collapse-container {
        display: none;
    }

  
}

@media (max-width: 480px) {
    .header-actions {
        margin-left: 10px;
    }

    .header-btn {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }

    .user-avatar {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }

    .content-area {
        padding: 10px;
    }

    .list-actions {
        flex-direction: column;
        gap: 10px;
    }

        .list-actions .el-button {
            width: 100%;
        }

 
}

/* 额外UI元素 */
.menu-toggle {
    display: none;
    margin-right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 30px;
    text-align: center;
    color: var(--gray-color);
}

    .empty-state i {
        font-size: 4rem;
        margin-bottom: 20px;
        color: #e0e0e0;
    }

    .empty-state h3 {
        font-size: 1.5rem;
        margin-bottom: 10px;
        color: var(--dark-color);
    }
     
 

.note-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 20px;
    background: #eef2ff;
    color: var(--primary-color);
    font-size: 0.85rem;
    margin: 0 5px 5px 0;
    transition: all 0.2s;
    cursor: pointer;
}

    .note-tag:hover {
        background: #dfe4ff;
    }

    .note-tag i {
        margin-left: 5px;
        font-size: 0.8rem;
        opacity: 0.7;
    }

    .note-tag:hover i {
        opacity: 1;
    }

/* 编辑器标签区域 */
.editor-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
}

.add-tag-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f0f2f5;
    color: #606266;
    cursor: pointer;
    transition: all 0.2s;
}

    .add-tag-btn:hover {
        background: #e4e7ff;
        color: var(--primary-color);
    }

/* 移动端标签按钮 */
.mobile-tag-btn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.3);
    z-index: 100;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
}

@media (max-width: 768px) {
    .mobile-tag-btn {
        display: flex;
    }
}
